package com.learn.spring;

import com.learn.spring.service.BookService;
import com.learn.spring.service.BookServiceImp;

/**
 * @author zhongshitao
 * @date 2020/9/24 10:03 上午
 */
public class StaticProxy implements BookServiceImp {

    private BookService bookService;

    public StaticProxy(BookService bookService) {
        this.bookService = bookService;
    }

    @Override
    public void buyBook(String bookName) {
        System.out.println("去书店买书");
        bookService.buyBook(bookName);
        System.out.println("回家....");
    }
}
